1. Field of the Invention
The invention relates to a variable length coding apparatus and method for motion vectors to be used in highly efficient coding of a moving picture signal, on the basis, for example, of interframe correlation.
2. Description of the Prior Art
When coding which utilizes interframe correlation is performed in connection with highly efficient coding of a moving picture signal, differences between frames are coded and, a motion vector is used to account for movement between two frames.
More specifically, a picture is divided into blocks of a predetermined size (for example, 16.times.16 picture elements as shown in FIG. 1A) and a motion vector indicates that a certain block the (objective block 11) has moved to another position on a second picture from which a difference is taken (as shown in FIG. 1B).
When a difference is taken between two frames after adjusting the second frame on the basis of a motion vector, the difference is minimized so that highly efficient coding can be performed. Conversely speaking, if the motion vector is obtained so that the difference between frames is minimized again highly efficient coding is made possible.
It is known to improve transmission efficiency of the motion vector, by using variable length coding of the motion vector. In particular, as shown in FIG. 2, picture data is supplied to a motion vector detecting circuit 10 which detects a motion vector, and the motion vector is then provided to a variable length coding circuit 20 and coded to provide a variable length coding code (VLC code).
Although the permissible range and degree of accuracy for the motion vector are theoretically unrestricted, and there are in fact practical limit such as hardware size, etc,. For example, consider the case in which variable length coding is to be performed the range of permissible range of the motion vector may be either .+-.7, picture elements or .+-.15 picture elements from the origin (i.e., the center), and the degree of accuracy may be 1 picture element unit or 0.5 picture element unit.
In this case two different variable length coding tables are needed for the 1 picture element degree of accuracy. That is, the table for the range of .+-.7 picture elements with 1 picture element accuracy has 15 elements 7, 6, . . . , 0, . . . , -6, -7, while the table for the range of .+-.15 picture elements with the same degree of accuracy has 31 elements 15, 14, . . . , 0, . . . , -14, -15. In addition, a table for the range of .+-.7 picture elements with 0.5 picture element which has 29 elements 7.0, 6.5, . . . , 0, . . . , -6.5, -7.0.
Accordingly, when there are plural kinds of motion vector ranges and there are plural degrees of accuracy, the number of tables that are needed increases, leading to more onerous hardware requirements.